\newproblem{lay:6_3_7}{
  % Problem identification
	\begin{large}
	  \hspace{\fill}\newline
    \textbf{Lay, 6.3.7}
	\end{large}
	\\
  \ifthenelse{\boolean{identifyAuthor}}{\textit{Carlos Oscar Sorzano, Aug. 31st, 2013} \\}{}

  % Problem statement
	Let $W$ be the space spanned by $\mathbf{u}_1=(1,3,-2)$ and $\mathbf{u}_2=(5,1,4)$ and let $\mathbf{y}=(1,3,5)$. Write $\mathbf{y}$ as the sum of a vector in $W$ and
	a vector orthogonal to $W$.
}{
   % Solution
	We project $\mathbf{y}$ onto $\mathrm{Span}\{\mathbf{u}_1,\mathbf{u}_2\}$
	\begin{center}
		$\begin{array}{rcl}
			\mathbf{x}_W&=&\frac{\mathbf{x}\cdot\mathbf{u}_1}{\mathbf{u}_1\cdot\mathbf{u}_1}\mathbf{u}_1+
			               \frac{\mathbf{x}\cdot\mathbf{u}_2}{\mathbf{u}_2\cdot\mathbf{u}_2}\mathbf{u}_2\\
									&=&\frac{0}{14}\begin{pmatrix}1\\3\\-2\end{pmatrix}+
										 \frac{28}{42}\begin{pmatrix}5\\1\\4\end{pmatrix}
									 =\begin{pmatrix}\frac{10}{3}\\ \frac{2}{3}\\ \frac{8}{3}\end{pmatrix}\\
		\end{array}$
	\end{center}
	To find the vector perpendicular to $W$, we simply calculate
	\begin{center}
		$\begin{array}{rcl}
			\mathbf{x}_{W^\perp}&=&\mathbf{x}-\mathbf{x}_W=\begin{pmatrix}-\frac{7}{3}\\ \frac{7}{3}\\ \frac{7}{3}\end{pmatrix}\\
		\end{array}$
	\end{center}
	By construction, we have $\mathbf{x}=\mathbf{x}_W+\mathbf{x}_{W^\perp}$.
}
\useproblem{lay:6_3_7}
\ifthenelse{\boolean{eachProblemInOnePage}}{\newpage}{}
